package br.fiap.util;

import javax.faces.event.PhaseEvent;
import javax.faces.event.PhaseId;
import javax.faces.event.PhaseListener;

import java.util.Date;
public class PhaseLogger implements PhaseListener{

    @Override
    public void afterPhase(PhaseEvent event) {
        System.out.println(new Date());
    }

    @Override
    public void beforePhase(PhaseEvent event) {
        System.out.println(event.getSource().getClass().getName());
    }

    @Override
    public PhaseId getPhaseId() {
        return PhaseId.ANY_PHASE;
    }



}
